package org.mics.hikariMonitor.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import org.mics.jpa.entity.BaseEntity;

import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * hikari监控详情
 * @author mics
 * @date 2022-7-21
 * @version  1.0
 */
@Data
@Entity
@Table(name="t_hikari_monitor_data")
@EqualsAndHashCode(callSuper = false)
public class HikariMonitorData extends BaseEntity{
	
    @Column(name = "server_port", columnDefinition = "varchar(32) comment '服务器端口'")
	private String serverPort;
    
    @Column(name = "total_connection", columnDefinition = "int(11) default 0 comment '总连接数'")
   	private int totalConnection;
    
    @Column(name = "active_connection", columnDefinition = "int(11) default 0 comment '激活连接数'")
   	private int activeConnection;
    
    @Column(name = "idle_connection", columnDefinition = "int(11) default 0 comment '空闲连接数'")
   	private int idleConnection;
    
    @Column(name = "thread_awaiting_connection", columnDefinition = "int(11) default 0 comment '等待中连接数'")
   	private int threadAwaitingConnection;
}
